* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Comic Sans MS', 'Arial Rounded MT Bold', 'Arial', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #333;
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

header {
    text-align: center;
    margin-bottom: 30px;
}

h1 {
    font-size: 3rem;
    color: #4a90e2;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.subtitle {
    font-size: 1.2rem;
    color: #666;
    font-weight: 500;
}

.clock-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 40px;
    gap: 20px;
}

.clock {
    width: 300px;
    height: 300px;
    border: 15px solid #4a90e2;
    border-radius: 50%;
    background: linear-gradient(145deg, #ffffff, #f0f0f0);
    box-shadow: 0 0 0 4px #fff, 0 0 0 8px #4a90e2, 0 20px 40px rgba(0, 0, 0, 0.2);
    position: relative;
    margin: 0 auto;
}

.clock-face {
    width: 100%;
    height: 100%;
    position: relative;
    border-radius: 50%;
}

.number {
    position: absolute;
    font-size: 1.5rem;
    font-weight: bold;
    color: #333;
    text-align: center;
    width: 30px;
    height: 30px;
    line-height: 30px;
}

.number-12 { top: 10px; left: 50%; transform: translateX(-50%); }
.number-1 { top: 25px; right: 75px; }
.number-2 { top: 75px; right: 25px; }
.number-3 { top: 50%; right: 10px; transform: translateY(-50%); }
.number-4 { bottom: 75px; right: 25px; }
.number-5 { bottom: 25px; right: 75px; }
.number-6 { bottom: 10px; left: 50%; transform: translateX(-50%); }
.number-7 { bottom: 25px; left: 75px; }
.number-8 { bottom: 75px; left: 25px; }
.number-9 { top: 50%; left: 10px; transform: translateY(-50%); }
.number-10 { top: 75px; left: 25px; }
.number-11 { top: 25px; left: 75px; }

.hand {
    position: absolute;
    bottom: 50%;
    left: 50%;
    transform-origin: bottom;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.hour-hand {
    width: 6px;
    height: 25%;
    background: #333;
    transform: translateX(-50%) rotate(0deg);
    z-index: 10;
}

.minute-hand {
    width: 4px;
    height: 35%;
    background: #666;
    transform: translateX(-50%) rotate(0deg);
    z-index: 11;
}

.second-hand {
    width: 2px;
    height: 40%;
    background: #e74c3c;
    transform: translateX(-50%) rotate(0deg);
    z-index: 12;
}

.center-dot {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 12px;
    height: 12px;
    background: #333;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    z-index: 13;
}

.time-display {
    text-align: center;
    margin-top: 20px;
}

.digital-time {
    font-size: 2.5rem;
    font-weight: bold;
    color: #4a90e2;
    margin-bottom: 10px;
    font-family: 'Courier New', monospace;
}

.time-text {
    font-size: 1.2rem;
    color: #666;
    font-weight: 500;
}

.controls {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.control-group {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 15px;
    border: 2px solid #e9ecef;
}

.control-group h3 {
    color: #4a90e2;
    margin-bottom: 20px;
    font-size: 1.3rem;
    text-align: center;
}

.time-inputs {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    justify-content: center;
}

.input-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.input-group label {
    font-weight: bold;
    color: #555;
    font-size: 0.9rem;
}

.input-group input {
    width: 60px;
    padding: 8px;
    border: 2px solid #ddd;
    border-radius: 8px;
    text-align: center;
    font-size: 1rem;
    font-weight: bold;
}

.input-group input:focus {
    outline: none;
    border-color: #4a90e2;
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.1);
}

.btn {
    padding: 12px 20px;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 5px;
    font-family: inherit;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.btn.primary {
    background: linear-gradient(135deg, #4a90e2, #357abd);
    color: white;
}

.btn.secondary {
    background: linear-gradient(135deg, #6c757d, #5a6268);
    color: white;
}

.btn.learning {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
}

.quick-buttons, .learning-modes {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.practice-panel, .quiz-panel {
    background: #fff3cd;
    border: 2px solid #ffeaa7;
    border-radius: 15px;
    padding: 25px;
    margin-top: 20px;
    text-align: center;
}

.practice-panel h3, .quiz-panel h3 {
    color: #856404;
    margin-bottom: 15px;
}

.practice-controls {
    margin: 20px 0;
}

.practice-result, .quiz-result {
    margin-top: 15px;
    padding: 10px;
    border-radius: 8px;
    font-weight: bold;
}

.practice-result.correct {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.practice-result.incorrect {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.quiz-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.quiz-option {
    padding: 15px;
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: bold;
}

.quiz-option:hover {
    background: #e9ecef;
    border-color: #4a90e2;
}

.quiz-option.selected {
    background: #4a90e2;
    color: white;
    border-color: #4a90e2;
}

.quiz-option.correct {
    background: #28a745;
    color: white;
    border-color: #28a745;
}

.quiz-option.incorrect {
    background: #dc3545;
    color: white;
    border-color: #dc3545;
}

@media (max-width: 768px) {
    .container {
        padding: 20px;
        margin: 10px;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .clock {
        width: 250px;
        height: 250px;
        border-width: 12px;
    }
    
    .number {
        font-size: 1.2rem;
    }
    
    .digital-time {
        font-size: 2rem;
    }
    
    .controls {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .time-inputs {
        flex-direction: column;
        align-items: center;
    }
    
    .input-group input {
        width: 80px;
    }
    
    .quick-buttons, .learning-modes {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
        margin: 5px 0;
    }
}

@media (max-width: 480px) {
    .clock {
        width: 200px;
        height: 200px;
        border-width: 10px;
    }
    
    .number {
        font-size: 1rem;
    }
    
    .hand {
        border-radius: 2px;
    }
    
    .hour-hand {
        width: 4px;
    }
    
    .minute-hand {
        width: 3px;
    }
    
    .second-hand {
        width: 1px;
    }
    
    .center-dot {
        width: 8px;
        height: 8px;
    }
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.clock:hover {
    animation: pulse 2s infinite;
}

@keyframes success {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

.success-animation {
    animation: success 0.5s ease;
} 